1. Technical Field
The present invention relates in general to the data processing field. More specifically, the present invention relates to tables implemented in software executing on a general purpose digital computer.
2. Background Art
Since the dawn of the computer age, computer systems have evolved into extremely sophisticated devices, and computer systems may be found in many different settings. Computer systems typically include a combination of hardware, such as semiconductors and circuit boards, and software, also known as computer programs. As advances in semiconductor processing and computer architecture push the performance of the computer hardware higher, more sophisticated computer software has evolved to take advantage of the higher performance of the hardware, resulting in computer systems today that are much more powerful than just a few years ago.
Tables are a common data structure used by many software applications. A spreadsheet is an example of a software application that implements a table, and that can perform various numerical and other operations on information that a user enters into the table. A spreadsheet typically has rows and columns of individual xe2x80x9ccellsxe2x80x9d, which can each contain information. The user can define various formulas in some of the cells for operating on the information residing in other cells. Examples of known spreadsheets include Lotus 1-2-3, Microsoft Excel, and Corel Quattro-Pro.
Modem spreadsheets typically provide functions that allow the user to select a block of rows and columns, and define tables, graphs, or other objects in various formats that reference and/or represent the data in the selected rows and columns. For example, a financial report for a company might include the rows of annual gross sales, cost of goods sold, and net profit in columns that represent different years. A user could select the data and define a bar chart object (or other type of object) that would graphically display each of these three items for each of the selected years.
Many modem applications allow referencing spreadsheet objects. For example, Microsoft provides an Object Link and Embed (OLE) capability in Excel that allows a spreadsheet object (such as a graph) to be defined as an OLE object and used in another document or application, such as a word processor. When existing data in the table changes, the data in the corresponding table or graph in the word processor automatically changes as well, eliminating the need to manually re-create tables and graphs that are generated from a spreadsheet. However, current technologies (such as OLE) that enable creation of objects do not recognize the addition of new data in a spreadsheet table. An OLE object has a data source that is defined by a fixed field of rows and columns, and anything outside that fixed field is not represented in the OLE object. As a result, when a new row or column is added to a spreadsheet table, the user must manually generate a new OLE object to include the new data. Because the spreadsheet controls the names of its objects, the user has no way to rename the new object so that existing documents can reference the new object instead of the old. Instead, the user must manually determine where the old object was used, and manually put in references to the new object. Needless to say, if an object is used in several different documents, this manual update process can become very tiresome, frustrating, and prone to error.
In most spreadsheets that track financial information, and in many other applications, new rows and/or columns will need to be added periodically as new months, quarters, and years roll by and their data becomes available. In addition, rows or columns may need to be deleted from time to time. Without an apparatus and method for automatically updating objects when new data is added to or deleted from their data source, users will continue to suffer from having to manually create new objects and replace existing references to the old object with references to the new object each and every time a new row or column is added to or deleted from the table that is the data source for the object.
An apparatus and method allow a user to define a dynamically extendible table in a software application, such as a spreadsheet. In one embodiment of the invention, when a new row or column is added next to a dynamically extendible table, the new row or column is automatically added to the definition of the dynamically extendible table. In a second embodiment of the invention, when a new row or column is added to a dynamically extendible table, the user is queried to determine whether the row or column should be added to the dynamically extendible table. In yet another embodiment, a user adds a row or column, then invokes a command to add the row or column to a dynamically extendible table. In one embodiment, once a dynamically extendible table has been updated to include a new row or column, any objects that use the dynamically extendible table as a data source are updated to include the new data. Because the name of the object doesn""t change, all documents that reference the old object will automatically reference the new object without changing any of the references in the documents. In another embodiment, once a dynamically extendible table has been updated to include a new row or column, all of the documents that reference an object that uses the table as a data source are then updated as required so that they reference either the old object or the new object, whichever is appropriate. As a result, all documents that reference the object and that require updating will refer to the new object automatically without requiring that the user manually create a new object to include the new row or column and manually change references to the old object to now refer to the new object. The present invention thus allows a user to add a row or column to a table, and the new data is then represented in objects that require updating.
The foregoing and other features and advantages of the invention will be apparent from the following more particular description of preferred embodiments of the invention, as illustrated in the accompanying drawings.